package com.ty.service;


import com.ty.entity.CategoryQuery;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ty.entity.Category;
import com.ty.dao.CategoryDao;

import java.util.List;


@Service
public class CategoryService{

    @Autowired
    private CategoryDao categoryDao;

    public List<Category> select(CategoryQuery query) {
        return categoryDao.select(query);
    }

    public Integer insert(Category category) {
        return categoryDao.insert(category);
    }

    public Integer update(Category category) {
        return categoryDao.update(category);
    }

    public Integer delete(Integer id) {
        return categoryDao.delete(id);
    }

}